/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package gradesjunit;

import org.junit.After;
import org.junit.AfterClass;
import org.junit.Before;
import org.junit.BeforeClass;
import org.junit.Test;
import static org.junit.Assert.*;








/**
 *
 * @author x00097734
 */
public class GradesJunitTest 
{
    
    public GradesJunitTest() 
    {
    }
    
    @BeforeClass
    public static void setUpClass() 
    {
    }
    
    @AfterClass
    public static void tearDownClass() 
    {
    }
    
    @Before
    public void setUp()
    {
    }
    
    @After
    public void tearDown() 
    {
    }

    /**
     * Test of main method, of class GradesJunit.
     */
    //@Test
    public void testMain()
    {
        System.out.println("main");
        String[] args = null;
        GradesJunit.main(args);
        // TODO review the generated test code and remove the default call to fail.
        fail("The test case is a prototype.");
    }

    /**
     * Test of grade method, of class GradesJunit.
     */
    @Test
    public void testGrade() 
    {
        System.out.println("grade");
        //preconditions
        int exam = 0;
        int ca = 0;
        String expResult = "Component Fail";
        String result = GradesJunit.grade(exam, ca);
        //postconditions
        assertEquals(expResult, result);  //JUnit includes these statstics into the percentage of successess and fails on the tests, Very Important.
        // TODO review the generated test code and remove the default call to fail.
        
    }
      @Test
    public void testGrade1() 
    {
        System.out.println("grade");
        //preconditions
        int exam =35 ;
        int ca = 35;
        String expResult = "Component Fail";
        String result = GradesJunit.grade(exam, ca);
        //postconditions
        assertEquals(expResult, result);  //JUnit includes these statstics into the percentage of successess and fails on the tests, Very Important.
        // TODO review the generated test code and remove the default call to fail.
        
    }
        @Test
    public void testGrade2() 
    {
        System.out.println("grade");
        //preconditions
        int exam = 35;
        int ca = 35;
        String expResult = "Component Fail";
        String result = GradesJunit.grade(exam, ca);
        //postconditions
        assertEquals(expResult, result);  //JUnit includes these statstics into the percentage of successess and fails on the tests, Very Important.
        // TODO review the generated test code and remove the default call to fail.
        
    }
          @Test
    public void testGrade3() 
    {
        System.out.println("grade");
        //preconditions
        int exam = 100;
        int ca = 100;
        String expResult = "Pass with Distinction";
        String result = GradesJunit.grade(exam, ca);
        //postconditions
        assertEquals(expResult, result);  //JUnit includes these statstics into the percentage of successess and fails on the tests, Very Important.
        // TODO review the generated test code and remove the default call to fail.
        
    }
            @Test
    public void testGrade4() 
    {
        System.out.println("grade");
        //preconditions
        int exam = 40;
        int ca = 45;
        String expResult = "Fail";
        String result = GradesJunit.grade(exam, ca);
        //postconditions
        assertEquals(expResult, result);  //JUnit includes these statstics into the percentage of successess and fails on the tests, Very Important.
        // TODO review the generated test code and remove the default call to fail.
        
    }
             @Test
    public void testGrade5() 
    {
        System.out.println("grade");
        //preconditions
        int exam = 90;
        int ca = 90;
        String expResult = "Pass with Distinction";
        String result = GradesJunit.grade(exam, ca);
        //postconditions
        assertEquals(expResult, result);  //JUnit includes these statstics into the percentage of successess and fails on the tests, Very Important.
        // TODO review the generated test code and remove the default call to fail.
        
    }

    /**
     * Test of computeFine method, of class GradesJunit.
     */
    @Test
    public void testComputeFine() 
    {
        System.out.println("computeFine");
        //preconditions
        String vehicle = "Car";
        int speed = 60;
        int zone = 30;
        String expResult = "EUR 50";
        String result = GradesJunit.computeFine(vehicle, speed, zone);
        //postconditions
        assertEquals(expResult, result);
        // TODO review the generated test code and remove the default call to fail.
        fail("The test case is a prototype.");
    }
     @Test
    public void testComputeFine1() 
    {
        System.out.println("computeFine");
         //preconditions
        String vehicle = "Bus";
        int speed = 30;
        int zone = 60;
        String expResult = "EUR 0";
        String result = GradesJunit.computeFine(vehicle, speed, zone);
        //postconditions
        assertEquals(expResult, result);
        // TODO review the generated test code and remove the default call to fail.
        fail("The test case is a prototype.");
    }
      @Test
    public void testComputeFine2() 
    {
        System.out.println("computeFine");
         //preconditions
        String vehicle = "Car";
        int speed = 100;
        int zone = 50;
        String expResult = "EUR 100";
        String result = GradesJunit.computeFine(vehicle, speed, zone);
        //postconditions
        assertEquals(expResult, result);
        // TODO review the generated test code and remove the default call to fail.
        fail("The test case is a prototype.");
    }
             
            
}